local wunvfu_skill = fk.CreateSkill {

  name = "wunvfu_skill",
  attached_equip = "wunvfu",
  tags = {},

}


wunvfu_skill:addEffect("viewas", {
  name = "wunvfu_skill",
  anim_type = "defensive",
  pattern = "nullification",
  prompt = "#wunvfu_skill_trigger-prompt",
  card_filter = Util.FalseFunc,
  view_as = function(self, player, cards)
    if #cards ~= 0 then
      return
    end
    local card = Fk:cloneCard("haorenka__nullification")
    card.skillName = self.name
    return card
  end,
  before_use = function(self, player, use)
    local room = player.room
    local judge = {
      who = player,
      reason = wunvfu_skill.name,
      pattern = ".|9~13"
    }
    room:judge(judge)
    if judge.card.number < 9 then
      return wunvfu_skill.name
    end
  end,
  enabled_at_response = function(self, player, response)
    return not response
  end,
  enabled_at_nullification = function(self, player, data)
    return data and data.card.trueName~="nullification" and data.to == player
  end,
})


return wunvfu_skill
